import { IsNotEmpty } from 'class-validator';
import { ApiProperty } from '@nestjs/swagger';

export class ArticleBodyDto {
  @ApiProperty({ description: '文章标题', example: '文章1' })
  @IsNotEmpty({ message: '请填写标题' })
  title: string;
  @ApiProperty({ description: '文章内容', example: '内容1' })
  @IsNotEmpty({ message: '请填写内容' })
  content: string;
}
